section .text							; the code properly

global _sti, _cli, _halt, _getCR0, _setCR0, _getCR3, _setCR3, _setIDT

_sti:
	sti
	ret

_cli:
	cli
	ret
	
_halt:
	ret

_getCR0:
	mov eax, cr0
	retn

_setCR0:
	push ebp
	mov ebp, esp
	mov eax, [ebp+8]
	mov cr0,  eax
	pop ebp
	retn

_getCR3:
	mov eax, cr3
	retn

_setCR3:
	push ebp
	mov ebp, esp
	mov eax, [ebp+8]
	mov cr3, eax
	pop ebp
	retn
	
_setIDT:
	;lidt [something]
	retn